/* ================================
   工作记录页面样式
   ================================ */

/* 背景渐变效果 */
.bg-dark-gradient {
    background: linear-gradient(135deg, #0f172a, #1e293b, #0f172a);
    background-size: 400% 400%;
    animation: gradientShift 8s ease infinite;
    min-height: 100vh;
    overflow-x: hidden; /* 防止水平滚动 */
    overflow-y: auto; /* 允许垂直滚动 */
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 主容器 */
.work-container {
    padding: var(--space-xl);
    max-width: 1400px;
    margin: 0 auto;
    color: white;
    animation: fadeInUp 0.8s ease-out;
    margin-top: 80px; /* 给顶部导航留出空间 */
    min-height: calc(100vh - 80px); /* 确保页面可以滚动 */
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ================================
   页面标题区域
   ================================ */

.work-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--space-2xl);
    padding-bottom: var(--space-xl);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.work-title {
    flex: 1;
}

.work-title i {
    font-size: 3rem;
    color: var(--accent-cyan);
    margin-right: var(--space-md);
    vertical-align: middle;
}

.work-title h1 {
    display: inline-block;
    font-size: var(--font-3xl);
    font-weight: 700;
    color: var(--primary-green);
    margin: 0;
    vertical-align: middle;
}

.work-title .subtitle {
    display: block;
    font-size: var(--font-lg);
    color: rgba(255, 255, 255, 0.7);
    margin-top: var(--space-sm);
    margin-left: 4.2rem;
}

/* 统计卡片区域 */
.work-stats {
    display: flex;
    gap: var(--space-lg);
}

.stat-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    display: flex;
    align-items: center;
    gap: var(--space-md);
    min-width: 140px;
    transition: all var(--duration-normal) ease;
}

.stat-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-green);
    transform: translateY(-2px);
    box-shadow: var(--shadow-neon);
}

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: rgba(76, 175, 80, 0.2);
    color: var(--primary-green);
    font-size: var(--font-xl);
}

.stat-icon.success {
    background: rgba(76, 175, 80, 0.2);
    color: var(--text-success);
}

.stat-icon.warning {
    background: rgba(255, 152, 0, 0.2);
    color: var(--text-warning);
}

.stat-icon.info {
    background: rgba(33, 150, 243, 0.2);
    color: var(--accent-blue);
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: var(--font-xl);
    font-weight: 700;
    color: white;
    line-height: 1.2;
}

.stat-label {
    font-size: var(--font-sm);
    color: rgba(255, 255, 255, 0.7);
    margin-top: var(--space-xs);
}

/* ================================
   搜索筛选区域
   ================================ */

.filter-section {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.filter-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.filter-label {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: var(--font-sm);
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
}

.filter-label i {
    color: var(--accent-cyan);
    width: 16px;
}

.filter-inputs {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.filter-input,
.filter-select {
    background: rgba(29, 43, 64, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-md);
    padding: var(--space-sm) var(--space-md);
    color: white;
    font-size: var(--font-base);
    transition: all var(--duration-normal) ease;
    width: 100%;
}

.filter-input:focus,
.filter-select:focus {
    border-color: var(--primary-green);
    background: rgba(29, 43, 64, 0.8);
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
}

.filter-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.filter-separator {
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--font-sm);
    white-space: nowrap;
}

.filter-actions {
    display: flex;
    gap: var(--space-md);
    margin-top: auto;
}

/* ================================
   表格区域
   ================================ */

.table-section {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
    padding-bottom: var(--space-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section-title {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    font-size: var(--font-xl);
    font-weight: 600;
    color: white;
}

.section-title i {
    color: var(--primary-green);
}

.section-actions {
    display: flex;
    gap: var(--space-md);
}

/* 表格容器 */
.table-container {
    background: rgba(29, 43, 64, 0.4);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid rgba(33, 150, 243, 0.2);
    box-shadow: var(--shadow-lg);
}

/* 表格基础样式 */
.work-table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--font-base);
    color: white;
}

.work-table thead th {
    background: rgba(29, 43, 64, 0.8);
    padding: var(--space-md);
    text-align: left;
    font-weight: 600;
    color: var(--accent-cyan);
    border-bottom: 2px solid var(--primary-green);
    font-size: var(--font-base);
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.work-table tbody tr {
    transition: all var(--duration-normal) ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.work-table tbody tr:hover {
    background: rgba(76, 175, 80, 0.08);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.1);
}

.work-table td {
    padding: var(--space-md);
    color: rgba(255, 255, 255, 0.9);
    font-size: var(--font-base);
    vertical-align: middle;
}

/* 记录ID样式 */
.record-id {
    font-family: 'Courier New', monospace;
    font-weight: 600;
    color: var(--accent-yellow) !important;
    background: rgba(255, 215, 0, 0.1);
    padding: var(--space-xs) var(--space-sm) !important;
    border-radius: var(--radius-sm);
    text-align: center;
    min-width: 120px;
}

/* 时间单元格 */
.time-cell {
    font-family: 'Courier New', monospace;
    color: rgba(255, 255, 255, 0.8);
    text-align: center;
    min-width: 80px;
}

/* 操作人员单元格 */
.operator-cell {
    min-width: 100px;
}

.operator-info {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}

.operator-info i {
    color: var(--accent-cyan);
    font-size: var(--font-lg);
}

.operator-info span {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* 操作类型徽章 */
.type-badge {
    display: inline-block;
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    font-size: var(--font-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 80px;
    text-align: center;
}

.type-badge.type-config {
    background: rgba(33, 150, 243, 0.2);
    color: var(--accent-blue);
    border: 1px solid rgba(33, 150, 243, 0.3);
}

.type-badge.type-scheme {
    background: rgba(76, 175, 80, 0.2);
    color: var(--text-success);
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.type-badge.type-system {
    background: rgba(156, 39, 176, 0.2);
    color: #e1bee7;
    border: 1px solid rgba(156, 39, 176, 0.3);
}

.type-badge.type-maintenance {
    background: rgba(255, 152, 0, 0.2);
    color: var(--text-warning);
    border: 1px solid rgba(255, 152, 0, 0.3);
}

/* 内容单元格 */
.content-cell {
    max-width: 200px;
}

.content-preview {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 状态徽章 */
.status-badge {
    display: inline-block;
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-sm);
    font-size: var(--font-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 80px;
    text-align: center;
}

.status-badge.status-success {
    background: rgba(76, 175, 80, 0.2);
    color: var(--text-success);
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.status-badge.status-warning {
    background: rgba(255, 152, 0, 0.2);
    color: var(--text-warning);
    border: 1px solid rgba(255, 152, 0, 0.3);
}

.status-badge.status-error {
    background: rgba(255, 23, 68, 0.2);
    color: var(--text-error);
    border: 1px solid rgba(255, 23, 68, 0.3);
}

/* 耗时单元格 */
.duration-cell {
    font-family: 'Courier New', monospace;
    color: var(--accent-cyan) !important;
    text-align: right;
    font-weight: 600;
    min-width: 60px;
}

/* 操作按钮 */
.action-cell {
    display: flex;
    gap: var(--space-sm);
    justify-content: center;
    min-width: 80px;
}

.action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all var(--duration-normal) ease;
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    transform: scale(1.1);
}

.action-btn.view:hover {
    background: rgba(33, 150, 243, 0.3);
    border-color: var(--accent-blue);
    color: var(--accent-blue);
}

.action-btn.download:hover {
    background: rgba(76, 175, 80, 0.3);
    border-color: var(--primary-green);
    color: var(--primary-green);
}

/* ================================
   分页器样式
   ================================ */

.table-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: var(--space-xl);
    padding-top: var(--space-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pagination-info {
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--font-sm);
}

.pagination-controls {
    display: flex;
    gap: var(--space-sm);
}

.pagination-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 var(--space-sm);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-sm);
    color: rgba(255, 255, 255, 0.8);
    font-size: var(--font-sm);
    cursor: pointer;
    transition: all var(--duration-normal) ease;
}

.pagination-btn:hover:not(.disabled) {
    background: rgba(76, 175, 80, 0.2);
    border-color: var(--primary-green);
    color: var(--primary-green);
}

.pagination-btn.active {
    background: var(--primary-green);
    border-color: var(--primary-green);
    color: white;
    font-weight: 600;
}

.pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ================================
   响应式设计
   ================================ */

@media (max-width: 1200px) {
    .work-container {
        padding: var(--space-lg);
    }
    
    .work-header {
        flex-direction: column;
        gap: var(--space-lg);
        align-items: flex-start;
    }
    
    .work-stats {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }
    
    .filter-container {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    .work-container {
        padding: var(--space-md);
    }
    
    .work-stats {
        flex-direction: column;
    }
    
    .stat-card {
        min-width: unset;
    }
    
    .filter-container {
        grid-template-columns: 1fr;
    }
    
    .filter-inputs {
        flex-direction: column;
        gap: var(--space-sm);
    }
    
    .filter-separator {
        display: none;
    }
    
    .section-header {
        flex-direction: column;
        gap: var(--space-md);
        align-items: flex-start;
    }
    
    .table-container {
        overflow-x: auto;
    }
    
    .work-table {
        min-width: 1000px;
    }
    
    .table-pagination {
        flex-direction: column;
        gap: var(--space-md);
        align-items: center;
    }
}

/* ================================
   特殊动画效果
   ================================ */

.work-table tbody tr {
    animation: slideInLeft 0.6s ease-out;
    animation-fill-mode: both;
}

.work-table tbody tr:nth-child(1) { animation-delay: 0.1s; }
.work-table tbody tr:nth-child(2) { animation-delay: 0.15s; }
.work-table tbody tr:nth-child(3) { animation-delay: 0.2s; }
.work-table tbody tr:nth-child(4) { animation-delay: 0.25s; }
.work-table tbody tr:nth-child(5) { animation-delay: 0.3s; }
.work-table tbody tr:nth-child(6) { animation-delay: 0.35s; }
.work-table tbody tr:nth-child(7) { animation-delay: 0.4s; }
.work-table tbody tr:nth-child(8) { animation-delay: 0.45s; }

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 表格行数据加载闪烁效果 */
.work-table tbody tr::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(76, 175, 80, 0.05), transparent);
    animation: dataFlow 3s ease infinite;
    pointer-events: none;
}

@keyframes dataFlow {
    0%, 70% { left: -100%; opacity: 0; }
    80% { opacity: 1; }
    100% { left: 100%; opacity: 0; }
} 